<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        /* div[class]有某个属性
        div[class="one"]有某个属性,并且值为one
        div[class^="o"]有某个属性,并且以o开头
        div[class$=e]有某个属性,并且以e结尾
        div[class*"a"] 有某个属性,并且包含a */
        
        div[class] {
            width: 100px;
            height: 100px;
            background-color: red;
        }
    </style>
</head>

<body>
    <div class="one">1</div>
    <div class="two">2</div>
    <div class="three">3</div>
    <div class="four">4</div>
    <div>5</div>
</body>

</html>